Integrand size = 17, antiderivative size = 36 \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=-\frac {1}{2} \text {arctanh}(\sin (x)) \cos (x) \sqrt {a \sec ^2(x)}+\frac {1}{2} \sqrt {a \sec ^2(x)} \tan (x) \]
[Out]
Time = 0.12 (sec) , antiderivative size = 36, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.235, Rules used = {3738, 4210, 2691, 3855} \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\frac {1}{2} \tan (x) \sqrt {a \sec ^2(x)}-\frac {1}{2} \cos (x) \sqrt {a \sec ^2(x)} \text {arctanh}(\sin (x)) \]
[In]
[Out]
Rule 2691
Rule 3738
Rule 3855
Rule 4210
Rubi steps \begin{align*} \text {integral}& = \int \sqrt {a \sec ^2(x)} \tan ^2(x) \, dx \\ & = \left (\cos (x) \sqrt {a \sec ^2(x)}\right ) \int \sec (x) \tan ^2(x) \, dx \\ & = \frac {1}{2} \sqrt {a \sec ^2(x)} \tan (x)-\frac {1}{2} \left (\cos (x) \sqrt {a \sec ^2(x)}\right ) \int \sec (x) \, dx \\ & = -\frac {1}{2} \text {arctanh}(\sin (x)) \cos (x) \sqrt {a \sec ^2(x)}+\frac {1}{2} \sqrt {a \sec ^2(x)} \tan (x) \\ \end{align*}
Time = 0.06 (sec) , antiderivative size = 24, normalized size of antiderivative = 0.67 \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\frac {1}{2} \sqrt {a \sec ^2(x)} (-\text {arctanh}(\sin (x)) \cos (x)+\tan (x)) \]
[In]
[Out]
Time = 0.07 (sec) , antiderivative size = 39, normalized size of antiderivative = 1.08
method | result | size |
derivativedivides | \(\frac {\sqrt {a +a \tan \left (x \right )^{2}}\, \tan \left (x \right )}{2}-\frac {\sqrt {a}\, \ln \left (\sqrt {a}\, \tan \left (x \right )+\sqrt {a +a \tan \left (x \right )^{2}}\right )}{2}\) | \(39\) |
default | \(\frac {\sqrt {a +a \tan \left (x \right )^{2}}\, \tan \left (x \right )}{2}-\frac {\sqrt {a}\, \ln \left (\sqrt {a}\, \tan \left (x \right )+\sqrt {a +a \tan \left (x \right )^{2}}\right )}{2}\) | \(39\) |
risch | \(-\frac {i \sqrt {\frac {a \,{\mathrm e}^{2 i x}}{\left ({\mathrm e}^{2 i x}+1\right )^{2}}}\, \left ({\mathrm e}^{2 i x}-1\right )}{{\mathrm e}^{2 i x}+1}+\sqrt {\frac {a \,{\mathrm e}^{2 i x}}{\left ({\mathrm e}^{2 i x}+1\right )^{2}}}\, \ln \left ({\mathrm e}^{i x}-i\right ) \cos \left (x \right )-\sqrt {\frac {a \,{\mathrm e}^{2 i x}}{\left ({\mathrm e}^{2 i x}+1\right )^{2}}}\, \ln \left ({\mathrm e}^{i x}+i\right ) \cos \left (x \right )\) | \(100\) |
[In]
[Out]
none
Time = 0.27 (sec) , antiderivative size = 47, normalized size of antiderivative = 1.31 \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\frac {1}{4} \, \sqrt {a} \log \left (2 \, a \tan \left (x\right )^{2} - 2 \, \sqrt {a \tan \left (x\right )^{2} + a} \sqrt {a} \tan \left (x\right ) + a\right ) + \frac {1}{2} \, \sqrt {a \tan \left (x\right )^{2} + a} \tan \left (x\right ) \]
[In]
[Out]
\[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\int \sqrt {a \left (\tan ^{2}{\left (x \right )} + 1\right )} \tan ^{2}{\left (x \right )}\, dx \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 295 vs. \(2 (28) = 56\).
Time = 0.57 (sec) , antiderivative size = 295, normalized size of antiderivative = 8.19 \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\frac {{\left (4 \, {\left (\sin \left (3 \, x\right ) - \sin \left (x\right )\right )} \cos \left (4 \, x\right ) - {\left (2 \, {\left (2 \, \cos \left (2 \, x\right ) + 1\right )} \cos \left (4 \, x\right ) + \cos \left (4 \, x\right )^{2} + 4 \, \cos \left (2 \, x\right )^{2} + \sin \left (4 \, x\right )^{2} + 4 \, \sin \left (4 \, x\right ) \sin \left (2 \, x\right ) + 4 \, \sin \left (2 \, x\right )^{2} + 4 \, \cos \left (2 \, x\right ) + 1\right )} \log \left (\cos \left (x\right )^{2} + \sin \left (x\right )^{2} + 2 \, \sin \left (x\right ) + 1\right ) + {\left (2 \, {\left (2 \, \cos \left (2 \, x\right ) + 1\right )} \cos \left (4 \, x\right ) + \cos \left (4 \, x\right )^{2} + 4 \, \cos \left (2 \, x\right )^{2} + \sin \left (4 \, x\right )^{2} + 4 \, \sin \left (4 \, x\right ) \sin \left (2 \, x\right ) + 4 \, \sin \left (2 \, x\right )^{2} + 4 \, \cos \left (2 \, x\right ) + 1\right )} \log \left (\cos \left (x\right )^{2} + \sin \left (x\right )^{2} - 2 \, \sin \left (x\right ) + 1\right ) - 4 \, {\left (\cos \left (3 \, x\right ) - \cos \left (x\right )\right )} \sin \left (4 \, x\right ) + 4 \, {\left (2 \, \cos \left (2 \, x\right ) + 1\right )} \sin \left (3 \, x\right ) - 8 \, \cos \left (3 \, x\right ) \sin \left (2 \, x\right ) + 8 \, \cos \left (x\right ) \sin \left (2 \, x\right ) - 8 \, \cos \left (2 \, x\right ) \sin \left (x\right ) - 4 \, \sin \left (x\right )\right )} \sqrt {a}}{4 \, {\left (2 \, {\left (2 \, \cos \left (2 \, x\right ) + 1\right )} \cos \left (4 \, x\right ) + \cos \left (4 \, x\right )^{2} + 4 \, \cos \left (2 \, x\right )^{2} + \sin \left (4 \, x\right )^{2} + 4 \, \sin \left (4 \, x\right ) \sin \left (2 \, x\right ) + 4 \, \sin \left (2 \, x\right )^{2} + 4 \, \cos \left (2 \, x\right ) + 1\right )}} \]
[In]
[Out]
none
Time = 0.28 (sec) , antiderivative size = 40, normalized size of antiderivative = 1.11 \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\frac {1}{2} \, \sqrt {a} \log \left ({\left | -\sqrt {a} \tan \left (x\right ) + \sqrt {a \tan \left (x\right )^{2} + a} \right |}\right ) + \frac {1}{2} \, \sqrt {a \tan \left (x\right )^{2} + a} \tan \left (x\right ) \]
[In]
[Out]
Timed out. \[ \int \tan ^2(x) \sqrt {a+a \tan ^2(x)} \, dx=\int {\mathrm {tan}\left (x\right )}^2\,\sqrt {a\,{\mathrm {tan}\left (x\right )}^2+a} \,d x \]
[In]
[Out]